<style>
    .Evaluation {
        border-bottom: 2px solid red;
    }
    .carReverseTitle{
        width:60px;
        text-align: center;
    }
    .goodEvaTit{
        font-size: 16px
    }
    .goodEvaTop{
        font-weight: 600;
    }
    .goodEvaTop span{
        font-weight: 400;
        padding-left:4%
    }
    .changePath{
        text-align: right;
        float:right
    }
    .changePath a{
        color:#4E8ABF
    }
    .changePath a:hover{
        color:#5087DC;
        font-weight: 600
    }
    .goodEvaGrade{
        font-weight: 600;
        padding-left: 15px
    }

    .tapReverse,.badTapReverse{
        margin-bottom: 35px
    }
    .tapReverse ul,.badTapReverse ul{
        padding:0px;
    }
    .tapReverse ul li{
        width:6%;
        border:#F0E6DC solid 1px;
        background-color: #FBF7F4;
        color: #EE7117;
        height:30px;
        line-height:30px;
        text-align: center;
        float: left;
        margin-right: 20px
    }
    .goodEvaContent{
        float: left;
        padding-left: 15px;
        padding-right: 15px;
    }

    .badTapReverse ul li{
        width:6%;
        border:#F0E6DC solid 1px;
        background-color: #999999;
        color: #fff;
        height:30px;
        line-height:30px;
        text-align: center;
        float: left;
        margin-right: 20px
    }

    #carReverseC button{
        margin-left:15px;
    }

</style>
<div class="bg-light lter b-b wrapper-sm">
    <h1 class="m-n font-thin h4">反向评价</h1>
</div>

<div class="wrapper-sm">
    <div class="panel panel-default">
        <div class="wrapper-sm" ng-controller="carReverseCommentController">
                <div class="panel panel-default" id="carReverseC">
                    <div class="panel-heading font-bold">查询</div>
                    <div class="panel-body form-horizontal">
                        <div class="form-group">
                            <label class="control-label pull-left w-xss">调度专员</label>
                            <div class="col-md-2">
                                <select id="table_operationManage_dispatchOfficerId" name="dispatchOfficerId" class="form-control input-sm" ng-model="queryTerms.dispatchOfficerId" ng-options="x.id as x.realName for x in dispatchOfficerDropDown">
                                    <option value="">全部</option>
                                </select>
                            </div>
                            
                            <label class="control-label pull-left w-xss">客服专员</label>
                            <div class="col-md-2">
                                <select id="table_operationManage_customerServiceOfficerId" name="customerServiceOfficerId" class="form-control input-sm" ng-model="queryTerms.customerServiceOfficerId" ng-options="x.id as x.realName for x in customerServiceDropDown">
                                    <option value="">全部</option>
                                </select>
                            </div>
                        
                            <label class="control-label pull-left w-xss">合同号</label>
                            <div class="col-md-2">
                                <input type="text" class="form-control input-sm" id="fa-searchz" ng-model="queryTerms.contractNum" name="contract-num" placeholder="请输入合同号">
                            </div>

                            <label class="control-label pull-left w-xss">评价起始时间</label>
                            <div class="col-md-2 col-xs-12">
                                <div class="input-group input-group-sm date">
                                    <input id="commentStartTime" name="commentStartTime" datetimepicker plugintype="datetime" ng-model="queryTerms.commentStartTime" placeholder="起始时间" class="form-control" type="text" />
                                    <span id="openStartTime" class="input-group-addon curpoint">
                                        <span class="glyphicon glyphicon-calendar"></span>
                                    </span>
                                </div>
                            </div>

                        </div>


                        <div class="form-group">
                            <label class="control-label pull-left w-xss">评价结束时间</label>
                            <div class="col-md-2 col-xs-12">
                                <div class="input-group input-group-sm date">
                                    <input id="commentEndTime" name="commentEndTime" datetimepicker plugintype="datetime" ng-model="queryTerms.commentEndTime" placeholder="结束时间" class="form-control" type="text" />
                                    <span id="openEndTime" class="input-group-addon curpoint">
                                        <span class="glyphicon glyphicon-calendar"></span>
                                    </span>
                                </div>
                            </div>

                            <label class="control-label pull-left w-xss"></label>
                            <div class="col-md-2"></div> 
                            <label class="control-label pull-left w-xss"></label>
                            <div class="col-md-2"></div>  
                            <label class="control-label pull-left w-xss"></label> 
                        
                            <button ng-click="query()" class="btn btn-sm btn-default btn-addon" ng-class="{'disabled':querying}" ng-disabled="querying">
                                <i class="fa fa-search" ng-show="!querying"></i>
                                <i class="fa fa-spinner no-bordr" ng-show="querying" ng-class="{'fa-spin':querying}"></i>
                                <span ng-show="!querying">查询</span>
                                <span ng-show="querying">查询中...</span>
                            </button>
                        </div>
                    </div>
                </div>



            <label class="curpoint carReverseTitle Evaluation" id="goodEvaluation" ng-model="praiseCount" ng-click="goodEvaluation()">好评</label> /
            <label class="curpoint carReverseTitle" id="commenEvaluation" ng-click="commenEvaluation()">一般</label>/
            <label class="curpoint carReverseTitle" id="haveEvaluation" ng-click="badEvaluation()">差评</label>
            <div ng-if="goodIf">
                <div ng-repeat="item in goodArrList | orderBy:'-Time' track by $index">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            <div class="hbox goodEvaTit">
                                <label class="col-md-1 pull-left text-base m-t-xs goodEvaTop">序号 <span class="text-base text-left m-t-xs">{{item.index}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">评价人 <span class="text-base text-left m-t-xs">{{item.realName}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:right">评价时间<span class="text-base text-left m-t-xs">{{item.createTime}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">调度专员<span class="text-base text-left m-t-xs">{{item.dispatcherName}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">客服专员<span class="text-base text-left m-t-xs">{{item.customerServiceName}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">合同号<span class="text-base text-left m-t-xs">{{item.order_ContractNumber}}</span></label>
                                <label class="text-base text-left m-t-xs changePath"><a  ng-click="changePath(item)">发货单详情>></a></label>

                            </div>

                        </div>
                        <div class="panel-body">
                            <div class="col-md-3 form-group text-base">
                                <label ng-model="ss" class="goodEvaTop" style="padding-right:10px">评分</label>
                                <span uib-rating ng-model="item.rating" max="5" state-on="'fa fa-star text-warning'" state-off="'fa fa-star-o btn-link'" read-only="isReadonly"></span>
                                <b class="btn-link curpoint text-danger goodEvaGrade" ng-if="item.rating * 2 == 8">(好)</b>
                                <b class="btn-link curpoint text-danger goodEvaGrade" ng-if="item.rating * 2 > 8">(非常好)</b>
                                <!-- {{item.grade * 2 | numbersZero}} -->
                            </div>

                            <div class="line line-dashed b-b line-lg"></div>

                            <div class="col-md-12 form-group text-base tapReverse">
                                <ul ng-if="item.rate && item.rate !=''">

                                    <!-- {{item.ratingOptions}} -->
                                    <li ng-repeat="key in item.rate" >{{key}}</li>
                                </ul>
                            </div>

                            <label class="goodEvaTop goodEvaContent">评价内容</label>
                            <div class="col-sm-10">
                                {{item.content}}
                            </div>

                        </div>

                    </div>
                </div>
            </div>

            <div ng-if="commentIf">    
                <div ng-repeat="item in commentArrList track by $index ">
                    <div class="panel panel-default">
                        <div class="panel-heading">
                            <div class="hbox">
                                <label class="col-md-1 pull-left text-base m-t-xs goodEvaTop">序号 <span class="text-base text-left m-t-xs">{{item.index}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">评价人 <span class="text-base text-left m-t-xs">{{item.realName}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:right">评价时间<span class="text-base text-left m-t-xs">{{item.createTime}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">调度专员<span class="text-base text-left m-t-xs">{{item.dispatcherName}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">客服专员<span class="text-base text-left m-t-xs">{{item.customerServiceName}}</span></label>
                                <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">合同号<span class="text-base text-left m-t-xs">{{item.order_ContractNumber}}</span></label>
                                <label class="text-base text-left m-t-xs changePath"><a  ng-click="changePath(item)">发货单详情>></a></label>

                            </div>

                        </div>
                        <div class="panel-body">
                                <div class="col-md-3 form-group text-base">
                                    <label ng-model="ss" class="goodEvaTop" style="padding-right:10px">评分</label>
                                    <span uib-rating ng-model="item.rating" max="5" state-on="'fa fa-star text-warning'" state-off="'fa fa-star-o btn-link'" read-only="isReadonly"></span>
                                    <b class="btn-link curpoint text-danger goodEvaGrade" ng-if="item.rating == 3">(一般)</b>
                                    <!-- <b class="btn-link curpoint text-danger" ng-if="item.grade * 2 > 8">(非常好)</b> -->
                                    <!-- {{item.grade * 2 | numbersZero}} -->
                                </div>
    
                                <div class="line line-dashed b-b line-lg"></div>
    
                                <div class="col-md-12 form-group text-base tapReverse">
                                    <ul ng-if="item.rate && item.rate !=''">
                                        <li ng-repeat="key in item.rate">{{key}}</li>
                                    </ul>
                                </div>
    
                                <label class="goodEvaTop goodEvaContent" style="float:left">评价内容</label>
                                <div class="col-sm-10">
                                    {{item.content}}
                                </div>
    
                            </div>

                    </div>
                </div>
            </div>

            <div ng-if="badIf">
                    <div ng-repeat="item in badArrList  | orderBy:'-Time' track by $index ">
                        <div class="panel panel-default">
                            <div class="panel-heading">
                                <div class="hbox">
                                        <label class="col-md-1 pull-left text-base m-t-xs goodEvaTop">序号 <span class="text-base text-left m-t-xs">{{item.index}}</span></label>
                                        <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">评价人 <span class="text-base text-left m-t-xs">{{item.realName}}</span></label>
                                        <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:right">评价时间<span class="text-base text-left m-t-xs">{{item.createTime}}</span></label>
                                        <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">调度专员<span class="text-base text-left m-t-xs">{{item.dispatcherName}}</span></label>
                                        <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">客服专员<span class="text-base text-left m-t-xs">{{item.customerServiceName}}</span></label>
                                        <label class="col-md-2 pull-left text-base m-t-xs goodEvaTop" style="text-align:center">合同号<span class="text-base text-left m-t-xs">{{item.order_ContractNumber}}</span></label>
                                        <label class="text-base text-left m-t-xs changePath"><a  ng-click="changePath(item)">发货单详情>></a></label>

                                </div>
    
                            </div>
                            <div class="panel-body">
                                <div class="col-md-3 form-group text-base">
                                    <label ng-model="ss" class="goodEvaTop" style="padding-right:10px">评分</label>
                                    <span uib-rating ng-model="item.rating" max="5" state-on="'fa fa-star text-warning'" state-off="'fa fa-star-o btn-link'" read-only="isReadonly"></span>
                                    <b class="btn-link curpoint text-success goodEvaGrade" ng-if="item.rating == 2">(差)</b>
                                    <b class="btn-link curpoint text-success goodEvaGrade" ng-if="item.rating ==1 ">(非常差)</b>
                                    <!-- {{item.grade * 2 | numbersZero}} -->
                                </div>
        
                                <div class="line line-dashed b-b line-lg"></div>
        
                                <div class="col-md-12 form-group text-base badTapReverse">
                                    <ul ng-if="item.rate && item.rate !=''">
                                        <li ng-repeat="key in item.rate">{{key}}</li>
                                    </ul>
                                </div>
        
                                <label class="goodEvaTop goodEvaContent" style="float:left">评价内容</label>
                                <div class="col-sm-10">
                                    {{item.content}}
                                </div>
    
                            </div>
        
                        </div>
                    </div>
            </div>

            <!-- {{currentPages}} -->
            <!-- <ul uib-pagination items-per-page="max" ng-change="pageChanged(currentPages)" total-items="totalItems" ng-model="currentPages" class="pagination-sm" previous-text="&lsaquo;" next-text="&rsaquo;" first-text="&laquo;" last-text="&raquo;">
                
            </ul> -->
            <tms-pagination ng-if="totalItems!=0" items-per-page="max" total-item='totalItems' current-page='currentPages' page-changed="pageChanged(currentPages)"></tms-pagination>
            <tms-pagination ng-if="totalItems==0" items-per-page="max" total-item='1' current-page='currentPages'></tms-pagination>
        </div>
    </div>
</div>